Copyright: Helpfile Generated by HelpWriter!


Contents - SetVol.DLL
SetVol.DLL - Contents

 WARNING

Introduction

SETVOL.DLL was written specifically for use with Visual Basic 16bit and other 16bit development environments to provide a means of changing the Volume Label or Deleting it:- functions which are not normally available within a programming system. The functions will only operate with disks formatted with Dos Versions 4.0 and later.  They will work with disks formatted with Windows 95 (DOS 7.0)

This control was written in Borland C++ (Version 5.01) by Darrin Edwards of  Innovative Solutions (Australia)  and is copyright accordingly.

TERMS

The control provided with this help file, is a trial version for evaluation purposes only - the control is not crippled in anyway - it simply has a Evaluation window which appears when the program is loaded or unloaded.  It is prohibited to distribute this version of the control with any application without the appropriate license.

It is legal for the original person in possession of the control and its associated files ("the package") to distribute the package as they received it, unmodified.  The original person in possession of this file is granted a limited license to use and apply the control to private use and for no other purpose.

The Registered version is supplied with a development license and consequential terms.  The registered version maybe distributed royalty free with your applications once purchased and does not have the Evaluation WIndow.

Ordering

Exported Functions

There are 3 exported functions of this control - for quick reference these are detailed below :

1·	ChVolLabel  	- a function to change the label

2·	DelVolLabel  	- a function to delete the label

3·	DriveInfo         	- a dialog box that allows access  to the volume functions

and provides the user with some disk information (disk size etc)

An example of the control's DriveInfo function - this is the window produced.

Copyright Innovative Solutions (Australia) 1997 - SetVol.Dll      14/10/1997 - Help file generated by VB HelpWriter.


ChVolLabel

Description

ChVolLabel changes the Volume Label of the selected disk.

Uses

iResult = ChVolLabel(iDriveNumber, sNewVolumeLabel)

- where iDriveNumber is equal to an integer as follows:

0 = Current Drive

1 = A Drive

2 = B Drive

3 = C Drive

4 = D Drive and so on

25 = Z Drive

- and where sNewVolumeLabel is a NULL terminsated string of a maximum of 11 characters.

and iResult is a variable initialised as integer type to take the return value.

Example VB Coding

' This code is to be placed in the forms declarations

' Set the Volume Label

Private Declare Function ChVolLabel Lib "setvol.dll" (ByVal iDrive _

As Integer, ByVal sVolumeName As String) As Integer

'Note : The above declaration must appear on one line

'Place this code in the form load event

Dim iCurrentDrive as Integer ' variable for drive

Dim nVolName as String     ' variable for Volume Label

iCurrentDrive = 3             ' C drive

nVolName = "NewLabel" ' the new label name

iResult = ChVolLabel(iCurrentDrive, nVolName)

     If iResult = 0 Then

          MsgBox "The Volume Label has now been set to : " _

          & nVolName & ".", vbOKOnly + vbInformation, _

          "SETVOL.DLL Confirmation"

     Else

          MsgBox "The Volume Label was unable to be set.", _

          vbOKOnly + vbInformation, "SETVOL.DLL Error"

     End If

Remarks

Copy the example Coding into the load event of a form.  Run the form, and the Volume Label for Drive "C" will be changed to "NewLabel".  For a further example, peruse the example file provided in this package.

Data Type

The Return Value of the function is an integer.

0 for success - any other number for failure.

WARNING

This function will only return information on disks formatted with MS DOS 4.0 and later, MS Windows 3.11 and later and IBM DOS Version 4.0 and later.  Any other version of DOS will provide unpredictable results.

Copyright Innovative Solutions (Australia) 1997 - SetVol.Dll      14/10/1997 - Help file generated by VB HelpWriter.


DelVolLabel

Description

This function deletes a Volume Label of the chosen drive.

Uses

iResult = DelVolLabel(iDriveNumber)

- where iDriveNumber is equal to an integer as follows:

0 = Current Drive

1 = A Drive

2 = B Drive

3 = C Drive

4 = D Drive and so on

25 = Z Drive

and iResult is a variable initialised as integer type to take the return value.

Example VB Coding

' This code is to be placed in the forms declarations

' Delete the Volume Label

Private Declare Function DelVolLabel Lib "setvol.dll" (ByVal iDrive As Integer) As Integer

'Note : The above declaration must appear on one line

'Place this code in the forms load event

Dim iCurrentDrive as Integer ' variable for drive

Dim nVolName as String     ' variable for Volume Label

iCurrentDrive = 3             ' C drive

iResult = DelVolLabel(iCurrentDrive)

     If iResult = 0 Then

          MsgBox "The Volume Label has now been Deleted.", _

          vbOKOnly + vbInformation, _

          "SETVOL.DLL Confirmation"

     Else

          MsgBox "The Volume Label was unable to be Deleted.", _

          vbOKOnly + vbInformation, "SETVOL.DLL Error"

     End If

Remarks

Copy the example Coding into the load event of a form.  Run the form, and the Volume Label for Drive "C" will be changed to "NewLabel".  For a further example, peruse the example file provided.

Data Type

The Return Value of the function is an integer.

0 for success - any other number for failure.

WARNING

This function will only return information on disks formatted with MS DOS 4.0 and later, MS Windows 3.11 and later and IBM DOS Version 4.0 and later.  Any other version of DOS will provide unpredictable results.

Copyright Innovative Solutions (Australia) 1997 - SetVol.Dll      14/10/1997 - Help file generated by VB HelpWriter.


DriveInfo

Description

This function displays a Dialog Box, with Disk Information such as FAT Type, Free Disk Space, Total Disk Space and Volume Name.  The Dialog box, offers the opportunity for the user to change the Volume Name or Delete it.

Uses

iResult = DriveInfol(hWin)

- where iResult is a variable initialised as integer type to take the return value

and hWin is an integer representing the value of the window handle, the dialogbox is to be displayed on top of.

Example VB Coding

' This code is to be placed in the forms declarations

' Delete the Volume Label

Private Declare Function DriveInfo Lib "setvol.dll" () As Integer

'Note : The above declaration must appear on one line

'Place this code in the forms load event

Dim hWnd as Integer

hWnd = form1.Hwnd

iResult = DriveInfo(hWnd)

     If iResult = 0 Then

          MsgBox "The DialogBox was successful.", _

          vbOKOnly + vbInformation, _

          "SETVOL.DLL Confirmation"

     Else

          MsgBox "The DDialogBox was unsuccessful.", _

          vbOKOnly + vbInformation, "SETVOL.DLL Error"

     End If

Remarks

Copy the example Coding into the load event of a form.  Run the form, and the DialogBox will be shown. For a further example, peruse the example file provided.

Data Type

The Return Value of the function is an integer.

0 for success - any other number for failure.

WARNING

This function will only return information on disks formatted with MS DOS 4.0 and later, MS Windows 3.1 and later and IBM DOS Version 4.0 and later.  Earlier versions will provide unpredictable results.

Copyright Innovative Solutions (Australia) 1997 - SetVol.Dll      14/10/1997 - Help file generated by VB HelpWriter.


Ordering

To order your version of SetVol.Dll

BY POST

- print the Order Form, fill it in  and post it together with your cheque in the sum of US$13.50

  (or US$15.50 for the source code) plus postage (US$6.00) to:

Darrin Edwards

Innovative Solutions (Australia)

3 Beverley Court

BRASSALL   QLD.  4305

AUSTRALIA

Postage is only payable once at the rate of US$6.00 provided all disks are to be sent to the same address (a maximum of 6 disks)

Note : Files are provided on 3.5" Floppy only.  Disks are sent by Registered post to the user , which accounts for the additional postage charges

BY SWREG

GO SWREG through Compuserve and register with SWREG #  16292

If you downloaded this file off one of the Compuserve Forums, then the price for this service is reduced as the commercial DLL file will be emailed to you (you have this help file to work with).  The price is a mere US$10.50.  Generally speaking, files are emailed within 36 hours of compuserve notifying us of your purchase and often earlier.

Other Means ?

We may accept other means of payment including joint venturing arrangements.  Please contact us further information.

Pricing Structure

Prices are subject to change without notification.  Please check with Innovative Solutions (Australia) for current pricing and updated files.

Copyright Innovative Solutions (Australia) 1997 - SetVol.Dll      14/10/1997 - Help file generated by VB HelpWriter.


Ordering / Registration

To Register or Order your DLL, please complete the following order form and remit by facsimile, email or post (or order through SWREG # 16292).

To :

Darrin Edwards

Innovative Solutions (Australia)

3 Beverley Court

BRASSALL   QLD.  4305

Australia

Ph.  0011 61 7 3021 5142  Fax : 0011 61 7 3201 4559

CIS :  100234.523,@Compuserve.com

Company Name :	_____________________________________
Address :	_________________________________________
	_____________________________________
Phone :	_____________________________________
Facsimile :	______________________________________
Email :	_____________________________________
Contact name :	_____________________________________
Position :	________________________________________
Product :	SetVol.Dll
Quantity  ______ @ US$13.50	$___________
Source Code : _____ @US15.50	$___________
Postage :                             $6.00

Total :                               $_____:_____

I, ________________________ of ____________________________________ hereby place the abovementioned order for the identified product and irrevocably agree to the terms of the license as appear in the help file known as "SetVol.HLP".

Signed : 	____________________________________

Date :	_____/_____/199__

Name :	____________________________________

(Please print)

Copyright Innovative Solutions (Australia) 1997 - SetVol.Dll      14/10/1997 - Help file generated by VB HelpWriter.


License Terms

Innovative Solutions (Australia) (herein after referred to as "ISA") grants a license to use SETVOL.DLL (herein after referred to as the "software" and or "the control")  to the original purchaser to use the software in accordance with this license only.  Copies may be made for back-up purposes only.  Copies made for any other purpose are expressly prohibited except in accordance with this license, and the adherence to this requirement is the sole responsibility of the purchaser.

Customer written executable applications calling to or containing embedded ISA product may be freely distributed, without royalty payments to ISA, provided that such distributed ISA product is bound into these applications in such a way so as to prohibit separate use in design mode or within a development environment, and that such ISA product is distributed only in conjunction with the customers own software product.  The ISA  product may not be distributed by itself in any form without express written permission from ISA.

Neither source code for ISA products nor modified source code for ISA products may be distributed under any circumstances, nor may you distribute .OBJ, .LIB, .CSM, .LIC etc. files that contain code routines developed or believed to be developed, in part or whole, by ISA without the express written permission of ISA. This control may be used as a constituent control only if written permission has been first obtained and the compound control thus created is distributed with and as an integral part of an application.  Permission to use this control as a constituent control does not grant a right to distribute the license (LIC) file or any other file other than the control executable itself. This license may be transferred to a third party only if all existing copies of the software and its documentation are also transferred and removed from the original purchasers hardware.

This product is licensed for use by only one developer at a time.  ISA expressly prohibits installing this product on more than one computer if there is any chance that both copies will be used simultaneously by the same person or organisation as the original purchaser.  This restriction also extends to installation on a network server, if more than one workstation will be accessing the product.  All developers working on a project which includes a ISA product, even though not working directly with the ISA product, are required to purchase a license for that ISA product. Corporate Multi use versions are available by negotiation with ISA.

This software is provided as is :  Innovative Solutions (Australia), its servants agents or delagates make no warranty, expressed or implied or otherwise, with regard to the software, its merchantability, fitness for any purpose or any or other form of representation relating to the softwares compatability for hardware or specific use.  All implied warranties, including the warranties of merchantability and fitness for a particular use, are hereby excluded.

The use of the software binds the license holder its assigns and agents who expressly warrant by their use of the software they irrevocably agree to hold harmless and indemnify ISA its servants agents and assigns and any other person connected howsoever with ISA, from and against all actions suits claims and demands of whatsoever the nature relating to or arising from the use of the software and any damages resulting from the aforesaid.

LIABILITY (if any) IS LIMITED TO THE PURCHASE PRICE.  Under no circumstances shall Innovative Solutions (Australia) or the authors of this software be liable for any incidental or consequential damages, nor for any damages in excess of the original purchase price.

To be eligible for free technical support by telephone, the Internet, CompuServe, etc. and to ensure that you are notified of any future updates, please complete the enclosed registration card and return it to Innovative Solutions (Australia).

Copyright Innovative Solutions (Australia) 1997 - SetVol.Dll      14/10/1997 - Help file generated by VB HelpWriter.


wDiskVol

Description

Returns the Volume Label of the Chosen Disk.

Uses

DiskVol(vbString, iDriveType)

- where vbString is a variable initialised as a NULL terminated string of at least 16 characters and iDriveType is a number representing the drive, 1 = A, 2 = B 3 = C and so on.

Example VB Coding

'Sample VB Declaration

Private Declare Sub wDiskVol Lib "SetVol.dll" _

   (ByVal sVBString As String, ByVal iDrive As Integer)

'Sample VB Function

Dim iDrive as Integer

Dim sVolName as String

sVolName = String$(16,chr$(0))

iDriveType = 3

DISKVOL(sVolName, iDriveType) ' get the Serial Number of drive C

Label1.Caption = trim(sVolName)

Remarks

To use the example above, you must create a form and copy the declaration into the General Declarations.  Place on the form a label and call it label 1. Copy the code under the Sample Declaration into the General Declarations are on the form, then copy the Sample VB Function code into the form load event. Press F5 and run the program. When the program is run the label will fill with the Volume Label of the selected disk.

Data Type

Nil - no return Value

WARNING

This function will only return a Volume Label if the disk was formatted under Microsoft DOS Version 4 or greater. A DOS Version of less than version 4 has been found to provide unreliable results.

Copyright Innovative Solutions (Australia) 1997 - SetVol.Dll      14/10/1997 - Help file generated by VB HelpWriter.


C

control

D

Darrin Edwards

E

evaluation

I

Innovative Solutions (Australia)

ISA

S

SETVOL.DLL

W

WARNING


control

SetVol.Dll is the control referred to through the course of this file.


Darrin Edwards

the proprietor of Innovative Solutions (Australia)


evaluation

The Evaluation period can last as long as you like within reason, subject to your not utilising the control in any commercial or business orientated manner other than as described in this help file.


Innovative Solutions (Australia)

3 Beverley Court

BRASSALL  QLD.  4305

AUSTRALIA

Ph:   07 3201 5142

Fax:  07 3201 4559

CIS:  100234.523@compuserve.com

"Helping 16bit programmers"


ISA

Innovative Solutions (Australia)


SETVOL.DLL

A Dynamic Link Library that allows a programmer program functions to change set or delete the Volume Label of a selected disk drive.


WARNING

This software will only return information from the relevant disks (Hard or Floppy) if it was formatted with a version of DOS 4.0 or greater.